From: Jasper St. Pierre Date: Sat, 22 Sep 2012 22:57:57 +0000 (-0300) Subject: workspaceThumbnail: Fix the dynamic workspaces check for dragging X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~5690 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=4f359e62dfe812126cd5f7c9d6827a79a0b9894f;p=gnome-shell.git workspaceThumbnail: Fix the dynamic workspaces check for dragging Be able to move windows between workspaces with static workspaces enabled; the incorrect check here simply disabled all dragging operations. https://bugzilla.gnome.org/show_bug.cgi?id=684641 --- diff --git a/js/ui/workspaceThumbnail.js b/js/ui/workspaceThumbnail.js index ab2e7ad42..d0bc3e866 100644 --- a/js/ui/workspaceThumbnail.js +++ b/js/ui/workspaceThumbnail.js @@ -620,9 +620,7 @@ const ThumbnailsBox = new Lang.Class({ if (!source.realWindow && !source.shellWorkspaceLaunch && source != Main.xdndHandler) return DND.DragMotionResult.CONTINUE; - if (!Meta.prefs_get_dynamic_workspaces()) - return DND.DragMotionResult.CONTINUE; - + let canCreateWorkspaces = Meta.prefs_get_dynamic_workspaces(); let spacing = this.actor.get_theme_node().get_length('spacing'); this._dropWorkspace = -1; @@ -647,7 +645,7 @@ const ThumbnailsBox = new Lang.Class({ if (i == this._dropPlaceholderPos) targetBottom += this._dropPlaceholder.get_height(); - if (y > targetTop && y <= targetBottom && source != Main.xdndHandler) { + if (y > targetTop && y <= targetBottom && source != Main.xdndHandler && canCreateWorkspaces) { placeholderPos = i; break; } else if (y > targetBottom && y <= nextTargetTop) {